package com.eclab.util;

import java.util.HashMap;

public class Result {

    private String code;
    private String message;
    private Object result;
    private HashMap<String,Object> maps = new HashMap<>();

    public Result() {
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Object getResult() {
        return result;
    }

    public void setResult(Object result) {
        this.result = result;
    }

    public HashMap<String, Object> getMaps() {
        return maps;
    }

    public void setMaps(HashMap<String, Object> maps) {
        this.maps = maps;
    }

    public Result(String code, String message, Object result) {
        this.code = code;
        this.message = message;
        this.result = result;
    }

    public Result(String code, String message, Object result, HashMap<String, Object> maps) {
        this.code = code;
        this.message = message;
        this.result = result;
        this.maps = maps;
    }

    public void clean(){
        this.setCode(null);
        this.setResult(null);
        this.setMessage(null);
        this.setMaps(null);
    }
}
